package itsm.isperp.module.repository.app;

import itsm.isperp.framework.data.mybatis.dao.CUDMapper;
import itsm.isperp.module.entity.app.AppMessageSuccess;

import java.sql.Timestamp;
import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/// <summary>
/// 描述:app_message_success
/// 创建者:zhouhg
/// 创建时间:2013/7/31
/// </summary>
@Repository
public interface AppMessageSuccessMapper extends CUDMapper<AppMessageSuccess> {

	Integer findMyMessageCount(@Param("receiverId") String receiverId,
			@Param("readed") Boolean readed);

	void readAllLeaveMessage(@Param("sourceId") String sourceId,
			@Param("username") String username,
			@Param("readTime") Timestamp readTime);

	List<Map<String, Object>> findCountsBySourceIds(
			@Param("sourceIds") String[] sourceIds,
			@Param("condition") String condition);

}
